<?php
namespace app\index\controller;
use think\Controller;
use think\Db;
use think\Request;
use think\Session;
class Index extends Common
{
    public function index()
    {
        $sql="select * from tp_activity ORDER BY id DESC LIMIT 4";
        $recent=Db::query($sql);
        $sql2="select * from tp_activity ORDER BY id DESC LIMIT 8";
        $news=Db::query($sql);
        $this->view->assign('recent',$recent);
        $this->view->assign('news',$news);
        return view();
    }
}
